package com.example.eduservice.client;

import com.example.commonutils.R;
import com.example.eduservice.entity.EduVideo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

//application文件中的服务名:service-vod
@FeignClient("service-vod")
@Component //交给spring管理
public interface VodClient {
    //定义调用的方法路径
    //根据视频id删除阿里云视频
    @DeleteMapping("/eduVod/video/removeAlyVideo/{id}")
    public R removeAlyVideo(@PathVariable("id") String id);

    //定义删除多个视频的方法
    @DeleteMapping("/eduVod/video/delete-batch")
    public R deleteBatch(List<String> videoIdList);
}
